package com.imc;

import java.util.Date;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.imc.bo.StaffBo;
import com.imc.domain.Staff;

public class Main {

	public static void main(String[] args) {
		ApplicationContext appContext = new ClassPathXmlApplicationContext(
				"ApplicationContext.xml");

		StaffBo staffBo = (StaffBo) appContext.getBean("staffBo");

		/** insert **/
		Staff staff = new Staff();
		staff.setName("Franco");
		staff.setSurname("Ferrero");
		staff.setAddress("Rastreador Fournier 190 ");
		staff.setBirthDate(new Date());
		staffBo.save(staff);

		System.out.println("Done");
	}
}
